#!/usr/bin/env bash

if [ "$1" == "-s" ]
then
#	wlp=$(ls ~/Wallpapers | ~/.config/hypr/scripts/dmenu.sh Wallpapers)
	wlp=$(ls ~/Wallpapers | wofi --width 300 --height 510 -i -d --prompt "Wallpapers")
	if [ ! -z $wlp ]
	then
		wlp_path="/home/gg/Wallpapers/"$wlp
		cp $wlp_path ~/.config/nixos/modules/hyprland/wal
		swaybg -i $wlp_path
#~/Sources/wal-telegram/wal-telegram --wal -g
	fi	
else
	killall swaybg
	swaybg -i ~/.config/nixos/modules/hyprland/wal
fi
